package com.ncloud.billing.mapper;

import java.util.List;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Result;
import org.apache.ibatis.annotations.Results;
import org.apache.ibatis.annotations.Select;

import com.ncloud.billing.entity.BsCust;

@Mapper
public interface BsCustMapper {
	@Select(value = {"SELECT cust_id, company_code, cust_name, cust_state, industry, create_time, create_user, update_time, update_user, remark FROM bs_cust "})
	@Results({ @Result(column = "cust_id", property = "custId"), @Result(column = "company_code", property = "companyCode"),
         @Result(column = "cust_name", property = "custName"),@Result(column = "cust_state", property = "custState"),
         @Result(column="create_time",property="createTime"),@Result(column="create_user",property="createUser"),
         @Result(column="update_time",property="updateTime"),@Result(column="update_user",property="updateUser"),
         @Result(column="remark",property="remark"),@Result(column = "industry", property = "industry")})
	public List<BsCust> getBsCustAll();
	
	@Select(value = {"SELECT cust_id, company_code, cust_name, cust_state, industry, create_time, create_user, update_time, update_user, remark FROM bs_cust "
			+ "where cust_id in (#{custIDs})"})
	@Results({ @Result(column = "cust_id", property = "custId"), @Result(column = "company_code", property = "companyCode"),
         @Result(column = "cust_name", property = "custName"),@Result(column = "cust_state", property = "custState"),
         @Result(column="create_time",property="createTime"),@Result(column="create_user",property="createUser"),
         @Result(column="update_time",property="updateTime"),@Result(column="update_user",property="updateUser"),
         @Result(column="remark",property="remark"),@Result(column = "industry", property = "industry")})
	public List<BsCust> getBsCustByCustID(String custIDs);
} 